package com.geekca.d5;

import java.lang.reflect.Array;
import java.util.Arrays;

public class OutputIntArr {
    public static void main(String[] args) {
        int[] arr1 = {11,22,33,44,55};
        outputArray(arr1);
    }

    public static void outputArray(int[] arr1){
        String before = "该数组内容为: ";

//        String after = Arrays.toString(arr1);
//
//        System.out.println(before+after);

        String after="[";
        for (int i = 0; i < arr1.length; i++) {
            after+=arr1[i]+", ";
        }

        after+="\b\b]";

        System.out.println(before+after);



    }
}
